package com.example.judge.service.judge;

import java.time.LocalDateTime;
import java.util.Stack;

public class Solution {

    public static int solution(int a, int b) {
        int c = a + b;
        return c;
    }

    public static boolean isValid(String str) {
        Stack<Character> stack = new Stack<>();
        for (int i = 0; i < str.length(); i++) {
            char c = str.charAt(i);
            if (c == '(' || c == '[' || c == '{') {
                stack.push(c);
            } else if (c == ')' || c == ']' || c == '}') {
                if (stack.isEmpty()) {
                    return false;
                }
                char topChar = stack.pop();
                if ((c == ')' && topChar != '(') ||
                        (c == ']' && topChar != '[') ||
                        (c == '}' && topChar != '{')) {
                    return false;
                }
            }
        }
        return stack.isEmpty();
    }

    public static void main(String[] args) {
//        int a = Integer.parseInt(args[0]);
//        int b = Integer.parseInt(args[1]);
//        System.out.println(solution(a, b));
        System.out.println(LocalDateTime.now());
    }
}
